package xyz.bali16.module.mute.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import xyz.bali16.module.mute.entity.Mute;
import xyz.bali16.module.mute.model.MuteAddParam;
import xyz.bali16.module.mute.model.MutePageParam;
import xyz.bali16.module.mute.model.MuteUpdateParam;

import java.text.ParseException;


/**
 * @author bali2 on 9/3/2023.
 * @version 1.0
 */
public interface MuteService extends IService<Mute> {
    IPage<Mute> getPage(MutePageParam param);
    void addMute(MuteAddParam param) throws Exception;

    void updateMute(MuteUpdateParam param) throws Exception;

    void delete(String navId) throws Exception;

    /**
     * 根据userId判断是否被禁言
     * @param userId
     * @return
     */
    boolean isMute(String userId) throws ParseException;

}
